<template>
	<div class="manualAdd">
		<el-breadcrumb separator="/" class="breadcrumb">
		  	<el-breadcrumb-item :to="{ path: '/waitPort/addPatients' }">添加患者</el-breadcrumb-item>
		  	<el-breadcrumb-item>完善患者信息</el-breadcrumb-item>	  
		</el-breadcrumb>
		<el-form :model="manadd" :rules="rules" ref="manadd" label-width="120px" class="demo-ruleForm">
			<div class="base-infor">
				<div class="title">
					基本信息
				</div>
				<div class="main">
					<div class="item">
					  <el-form-item label="姓名" prop='user'>
					    <el-input v-model="manadd.user" size='small'></el-input>
					  </el-form-item>
					  <el-form-item label="性别" prop='sex'>
					  	<el-select v-model="manadd.sex" placeholder="请选择" size='small'>
					  	  <el-option label="请选择" value=""></el-option>
					      <el-option label="男" value="男"></el-option>
					      <el-option label="女" value="女"></el-option>
					      <el-option label="未知" value="未知"></el-option>
					    </el-select>
					  </el-form-item>
					  <el-form-item label="出生年月" prop='birthday' >
					    <el-date-picker type="date" placeholder="选择日期" v-model='manadd.birthday' size='small'>
					    </el-date-picker>
					  </el-form-item>
					</div>
					<div class="item">
						<el-form-item label="身份证号" prop='idcard'>
							<el-input v-model="manadd.idcard" size='small'></el-input>
						</el-form-item>
						<el-form-item label="血型">
							<el-select v-model="manadd.blood" size='small' placeholder="请选择">
								<el-option label="请选择" value=""></el-option>
							    <el-option label="A" value="A"></el-option>
							    <el-option label="B" value="B"></el-option>
							    <el-option label="AB" value="AB"></el-option>
							    <el-option label="O" value="O"></el-option>
							</el-select>
						</el-form-item>
						<el-form-item label="既往移植史">
							<el-select v-model="manadd.history" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="有" value="有"></el-option>
								<el-option label="无" value="无"></el-option>
							</el-select>
						</el-form-item>
					</div>
					<div class="item">
						<el-form-item label="原发疾病" prop='disease'>
							<el-select v-model="manadd.disease" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="慢性肾炎" value="慢性肾炎"></el-option>
								<el-option label="尿毒症" value="尿毒症"></el-option>
							</el-select>
						</el-form-item>
						<el-form-item label="伴随发疾病" prop='follow'>
							<el-select v-model="manadd.follow" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="糖尿病" value="糖尿病"></el-option>
								<el-option label="高血压" value="高血压"></el-option>
							</el-select>
						</el-form-item>
						<el-form-item label="替代治疗方式" prop='replace'>
							<el-select v-model="manadd.replace" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="全阴性" value="全阴性"></el-option>
								<el-option label="全阳性" value="全阳性"></el-option>
								<el-option label="labScreen-l-DX阳性" value="labScreen-l-DX阳性"></el-option>
								<el-option label="labScreen-ll-DX阳性" value="labScreen-ll-DX阳性"></el-option>
							</el-select>
						</el-form-item>
					</div>
					<div class="item">
						<el-form-item label="联系方式1" prop='phone1'>
					      <el-input size='small' v-model='manadd.phone1'></el-input>
					   </el-form-item>
					   <el-form-item label="联系方式2">
							<el-input size='small' v-model='manadd.phone2'></el-input>
						</el-form-item>
					</div>
					<div class="item">
						<el-form-item label="登记时间" prop='register'>
					       <el-date-picker type="date" placeholder="选择日期"  style="width: 100%;" size='small' v-model='manadd.register'></el-date-picker>
					  </el-form-item>
					  <el-form-item label="居住地址">
					    <el-cascader
						    :options="options"
						     v-model="manadd.selectedOptions"
						    >
						  </el-cascader>
					 </el-form-item>
					</div>
				</div>
			</div>
			<div class="base-infor">
				<div class="title">
					*HLA配型信息
				</div>
				<div class="main">
					<div class="item">
						<div class="antigen-title">人类白细胞抗原A</div>
						<div class="antigen">
						<el-form-item label="A" label-width='50px'>
					    	<el-input v-model="manadd.antigenAmin" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					  	<div class="antigen">
					  	<el-form-item label="A"  label-width='50px'>
					    	<el-input v-model="manadd.antigenAmax" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					</div>
					<div class="item">
						<div class="antigen-title">人类白细胞抗原B</div>
						<div class="antigen">
						<el-form-item label="B" label-width='50px'>
					    	<el-input v-model="manadd.antigenBmin" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					  	<div class="antigen">
					  	<el-form-item label="B"  label-width='50px'>
					    	<el-input v-model="manadd.antigenBmax" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					</div>
					<div class="item">
						<div class="antigen-title">人类白细胞抗原A</div>
						<div class="antigen">
						<el-form-item label="DR" label-width='50px'>
					    	<el-input v-model="manadd.antigenDRmin" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					  	<div class="antigen">
					  	<el-form-item label="DR"  label-width='50px'>
					    	<el-input v-model="manadd.antigenDRmax" size='small'></el-input>
					  	</el-form-item>
					  	</div>
					</div>
				</div>
			</div>
			<div class="base-infor">
				<div class="title">
					*术前检查
				</div>
				<div class="main">
					<v-check></v-check>
				</div>
			</div>
			<div class="base-infor">
				<div class="title">
					术前四项
				</div>
				<div class="main">
					<div class="item">
					<div class="input-width">
					 <el-form-item label="乙肝表面抗原" label-width='150px'>
					    <el-select v-model="manadd.HBsAg" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="阴性" value="阴性"></el-option>
								<el-option label="阳性" value="阳性"></el-option>
							</el-select>
					  </el-form-item>
					  </div>
					  <div class="input-width">
					  <el-form-item label="丙型肝炎抗体" label-width='150px'>
					    <el-select v-model="manadd.Athc" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="阴性" value="阴性"></el-option>
								<el-option label="阳性" value="阳性"></el-option>
							</el-select>
					  </el-form-item>
					  </div>
					</div>
					<div class="item">
					<div class="input-width">
					 <el-form-item label="人免疫缺陷病毒抗体" label-width='150px'>
					    <el-select v-model="manadd.Hivn" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="阴性" value="阴性"></el-option>
								<el-option label="阳性" value="阳性"></el-option>
							</el-select>
					  </el-form-item>
					  </div>
					  <div class="input-width">
					  <el-form-item label="梅毒螺旋体抗体" label-width='150px'>
					    <el-select v-model="manadd.Tpn" placeholder="请选择" size='small'>
								<el-option label="请选择" value=""></el-option>
								<el-option label="阴性" value="阴性"></el-option>
								<el-option label="阳性" value="阳性"></el-option>
							</el-select>
					  </el-form-item>
					  </div>
					</div>
				</div>
			</div>
			<div class="button">
				<el-form-item label-width='0px'>
				<el-button type="primary" @click='submit(manadd)'>确认添加</el-button>
				</el-form-item>
			</div>
		</el-form>
	</div>
</template>
<script>
import check from './check'
export default {
	data(){
		return {
			options:[{
				value:'浙江省',
				label:'浙江省',
				children:[{
					value:'杭州市',
					label:'杭州市',
					children:[{
						value:'下城区',
						label:'下城区',
						children:[{
							value:'石桥街道',
							label:'石桥街道'
						}]
					}]
				}]
			}],
			manadd:{
				user:'',
				sex:'',
				birthday:'',
				idcard:'',
				disease:'',
				blood:'',
				history:'',
				follow:'',
				replace:'',
				phone1:'',
				phone2:'',
				register:'',
				antigenAmin:'',
				antigenAmax:'',
				antigenBmin:'',
				antigenBmax:'',
				antigenDRmin:'',
				antigenDRmax:'',
				HBsAg:'',
				Athc:'',
				Hivn:'',
				Tpn:'',
				selectedOptions:['浙江省','杭州市','下城区','石桥街道']
			},
			rules:{
				user:[{required:true}],
				sex:[{required:true}],
				birthday:[{required:true}],
				idcard:[{required:true}],
				disease:[{required:true}],
				replace:[{required:true}],
				phone1:[{required:true}],
				register:[{required:true}]
			}
		}
	},
	methods:{
		submit(formName){
			console.log(formName)
		}
	},
	components:{
		'v-check':check
	}
}	
</script>
<style lang='scss' rel='stylesheet/scss'>
	.manualAdd{
		.item{
			display: flex;
			.el-cascader{
				width: 300px;
			}
			.input-width{
				width: 260px;
				margin-right: 30px;
			}
			.antigen-title{
				line-height: 36px;
				margin-right: 100px;
			}
			.antigen{
				width: 130px;
			}
		}
		.button{
			display: flex;
			justify-content:center;
			margin:10px 0 10px 20px;
		}
	}
</style>